import os
lt = []
ct = 0
with open('fn.txt', 'r', encoding='utf-8') as fo:
    cnt = fo.read()
    ct = cnt.count(',')
print(ct)
#     lt = cnt.split('\n')
# lt = lt[1::2]
# # str1 = lt[14]
# # print(str1, len(str1))
# j = 0
# for i in range(len(lt)):
#     if len(lt[j]) == 28:
#         lt.pop(j)
#     else:
#         j += 1

# content = '\n'.join(lt)
# cnt = content.replace('ping 10.64.16.[51-70]失败：', ',')
# with open('fn.txt', 'w', encoding='utf-8') as fd:
#     fd.write(cnt)
# print(len(lt))

# # for i in range(10):
# #     ln = fo.readline()
# #     ll = fo.readline()
# #     print(ln)
# #     print(ll)
